package top.aigoo.project01.function;


import org.junit.Test;
import sun.misc.BASE64Encoder;

import javax.swing.*;
import java.util.Base64;
import java.util.Dictionary;

/**
 * @Description: 请填写该类完成的功能
 * @Author: Mr.OYSHUO.欧阳大叔  mail:1642302522@qq.com
 * @Version 1.0.0
 * @Date: 2021/9/18 15:29
 */
public class DESTestFunction {
    @Test
    public void testFunction(){
        String str = "0123456789ABCDEF";
        String strKey = "0E329232EA6D0D73";
        byte[] strBytes = str.getBytes();

        System.out.println("bytes lenght is:" + strBytes.length);
        for (byte strByte : strBytes) {
            System.out.print("---"+strByte+"---");
        }
        System.out.println();
        BASE64Encoder base64 = new BASE64Encoder();

        String encode = base64.encode(strBytes);
        System.out.println("64位加密后:"+encode);

    }
}
